import { useGetMyRequestQuery } from "@/app/user/userApi"
import { Input } from "@/shared/ui/input"

const MyRequestsPage = () => {
  const { data } = useGetMyRequestQuery(null, {
    refetchOnMountOrArgChange: true,
  })
  return (
    <div>
      {!data?.animal ? (
        "У вас еще нет запросов"
      ) : (
        <div>
          {data?.state === "Interview" ? (
            <div>
              <h1 className="scroll-m-20 text-4xl font-medium">
                Собеседование
              </h1>
              <div className="mt-6 flex flex-col gap-3">
                <h2 className="scroll-m-20 text-xl font-medium">Куратор</h2>
                <Input value={data.animal.curator.name} disabled />
                <Input value={data.animal.curator.phone} readonly />
              </div>
            </div>
          ) : (
            data.state
          )}
        </div>
      )}
    </div>
  )
}
export default MyRequestsPage
